home *** CD-ROM | disk | FTP | other *** search
/ Visual Basic Toolbox / Visual Basic Toolbox (P.I.E.)(1996).ISO / buttons / espin / form1.frm < prev    next >
Text File  |  1995-07-19  |  4KB  |  138 lines

  1. VERSION 2.00
  2. Begin Form Form1 
  3.    Caption         =   "Enhanced Spin Demo"
  4.    ClientHeight    =   3315
  5.    ClientLeft      =   1215
  6.    ClientTop       =   1605
  7.    ClientWidth     =   5445
  8.    Height          =   3750
  9.    Left            =   1140
  10.    LinkTopic       =   "Form1"
  11.    ScaleHeight     =   3315
  12.    ScaleWidth      =   5445
  13.    Top             =   1245
  14.    Width           =   5595
  15.    Begin TextBox Text2 
  16.       Height          =   285
  17.       Left            =   840
  18.       TabIndex        =   1
  19.       Text            =   "0"
  20.       Top             =   600
  21.       Width           =   975
  22.    End
  23.    Begin TextBox Text1 
  24.       FontBold        =   -1  'True
  25.       FontItalic      =   0   'False
  26.       FontName        =   "MS Sans Serif"
  27.       FontSize        =   13.5
  28.       FontStrikethru  =   0   'False
  29.       FontUnderline   =   0   'False
  30.       Height          =   495
  31.       Left            =   840
  32.       TabIndex        =   0
  33.       Text            =   "0"
  34.       Top             =   1620
  35.       Width           =   1335
  36.    End
  37.    Begin Label Label3 
  38.       Caption         =   "Click and hold on the up or down arrows.  Click on the center segment and drag up or down .  Try the other mouse button, too."
  39.       FontBold        =   0   'False
  40.       FontItalic      =   0   'False
  41.       FontName        =   "MS Sans Serif"
  42.       FontSize        =   8.25
  43.       FontStrikethru  =   0   'False
  44.       FontUnderline   =   0   'False
  45.       Height          =   675
  46.       Left            =   840
  47.       TabIndex        =   4
  48.       Top             =   2340
  49.       Width           =   3015
  50.    End
  51.    Begin Label Label2 
  52.       Caption         =   "This is what it looks like with the bitmap ""stretched"""
  53.       FontBold        =   0   'False
  54.       FontItalic      =   0   'False
  55.       FontName        =   "MS Sans Serif"
  56.       FontSize        =   8.25
  57.       FontStrikethru  =   0   'False
  58.       FontUnderline   =   0   'False
  59.       Height          =   435
  60.       Left            =   840
  61.       TabIndex        =   3
  62.       Top             =   1140
  63.       Width           =   2535
  64.    End
  65.    Begin Label Label1 
  66.       Caption         =   "This is the ""natural"" size of the button"
  67.       FontBold        =   0   'False
  68.       FontItalic      =   0   'False
  69.       FontName        =   "MS Sans Serif"
  70.       FontSize        =   8.25
  71.       FontStrikethru  =   0   'False
  72.       FontUnderline   =   0   'False
  73.       Height          =   255
  74.       Left            =   840
  75.       TabIndex        =   2
  76.       Top             =   300
  77.       Width           =   2895
  78.    End
  79.    Begin Image Image2 
  80.       BorderStyle     =   1  'Fixed Single
  81.       Height          =   300
  82.       Left            =   1800
  83.       Picture         =   FORM1.FRX:0000
  84.       Top             =   600
  85.       Width           =   195
  86.    End
  87.    Begin Image Image1 
  88.       BorderStyle     =   1  'Fixed Single
  89.       Height          =   495
  90.       Left            =   2160
  91.       Picture         =   FORM1.FRX:010A
  92.       Stretch         =   -1  'True
  93.       Top             =   1620
  94.       Width           =   375
  95.    End
  96. End
  97. Option Explicit
  98.  
  99. Sub Form_Load ()
  100. ' you need to load the ESpin form at startup:
  101.   Load FrmESpin
  102. End Sub
  103.  
  104. Sub Form_Unload (Cancel As Integer)
  105.   Unload FrmESpin
  106.   End
  107. End Sub
  108.  
  109. Sub Image1_MouseDown (Button As Integer, Shift As Integer, X As Single, Y As Single)
  110. ' 3rd parameter is always the name of *this* control
  111. ' 4th parameter is name of the e.g. textbox to spin
  112.   JDMouseDown Button, Y, Image1, Text1
  113. End Sub
  114.  
  115. Sub Image1_MouseMove (Button As Integer, Shift As Integer, X As Single, Y As Single)
  116. ' 2nd parameter is the name of *this* control
  117.   JDMouseMove Y, Image1, Button
  118. End Sub
  119.  
  120. Sub Image1_MouseUp (Button As Integer, Shift As Integer, X As Single, Y As Single)
  121.   JDMouseUp
  122. End Sub
  123.  
  124. Sub Image2_MouseDown (Button As Integer, Shift As Integer, X As Single, Y As Single)
  125. ' 3rd parameter is always the name of *this* control
  126. ' 4th parameter is name of the e.g. textbox to spin
  127.   JDMouseDown Button, Y, Image2, Text2
  128. End Sub
  129.  
  130. Sub Image2_MouseMove (Button As Integer, Shift As Integer, X As Single, Y As Single)
  131.   JDMouseMove Y, Image2, Button
  132. End Sub
  133.  
  134. Sub Image2_MouseUp (Button As Integer, Shift As Integer, X As Single, Y As Single)
  135.   JDMouseUp
  136. End Sub
  137.  
  138.